package com.easy.dfc.mapper;


import com.easy.core.persistence.annotation.MyBatisMapper;
import com.easy.dfc.entity.FactoryInfo;
import com.easy.dfc.entity.ProductInfo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@MyBatisMapper

public interface UserFFFMapper {

    Integer getFavoriteNum(@Param(value = "userId") String userId, @Param(value = "type") Integer type);

    Integer getFollowNum(@Param(value = "userId") String userId, @Param(value = "type") Integer type);

    Integer getFootStepNum(@Param(value = "userId") String userId, @Param(value = "type") Integer type);

    List<ProductInfo> FavoriteProduct(@Param(value = "userId") String userId, @Param(value = "pageIndex") Integer pageIndex, @Param(value = "pageSize") Integer pageSize);

    List<ProductInfo> FollowProduct(@Param(value = "userId") String userId, @Param(value = "pageIndex") Integer pageIndex, @Param(value = "pageSize") Integer pageSize);

    List<ProductInfo> FootStepProduct(@Param(value = "userId") String userId, @Param(value = "pageIndex") Integer pageIndex, @Param(value = "pageSize") Integer pageSize);

    List<FactoryInfo> FavoriteFactory(@Param(value = "userId") String userId, @Param(value = "pageIndex") Integer pageIndex, @Param(value = "pageSize") Integer pageSize);

    List<FactoryInfo> FollowFactory(@Param(value = "userId") String userId, @Param(value = "pageIndex") Integer pageIndex, @Param(value = "pageSize") Integer pageSize);

    List<FactoryInfo> FootStepFactory(@Param(value = "userId") String userId, @Param(value = "pageIndex") Integer pageIndex, @Param(value = "pageSize") Integer pageSize);

    void AddFavorite(@Param(value = "userId")String userId, @Param(value = "objectId")String objectId, @Param(value = "type")Integer type);

    void AddFollow(@Param(value = "userId")String userId, @Param(value = "objectId")String objectId, @Param(value = "type")Integer type);

    void AddFootStep(@Param(value = "userId")String userId, @Param(value = "objectId")String objectId, @Param(value = "type")Integer type);

    void DelFavorite(@Param(value = "userId")String userId, @Param(value = "objectId")String objectId, @Param(value = "type")Integer type);

    void DelFollow(@Param(value = "userId")String userId, @Param(value = "objectId")String objectId, @Param(value = "type")Integer type);

    void DelFootStep(@Param(value = "userId")String userId, @Param(value = "objectId")String objectId, @Param(value = "type")Integer type);

    Integer getFollowFactoryByUserFactoryId(@Param(value = "userId")String userId, @Param(value = "factoryId")String factoryId);

    Integer getFollowFactoryByFactoryId(@Param(value = "factoryId")String factoryId);

    int HaveFavorite(@Param(value = "userId")String userId, @Param(value = "objectId")String objectId, @Param(value = "type")Integer type);

    int HaveFollow(@Param(value = "userId")String userId, @Param(value = "objectId")String objectId, @Param(value = "type")Integer type);

    List<ProductInfo> FavoriteProductOld(@Param(value = "userId") String userId, @Param(value = "pageIndex") Integer pageIndex, @Param(value = "pageSize") Integer pageSize);

    List<FactoryInfo> FollowFactoryOld(@Param(value = "userId") String userId, @Param(value = "pageIndex") Integer pageIndex, @Param(value = "pageSize") Integer pageSize);
}